﻿#region [ License information          ]
/* ************************************************************
 *
 * Copyright (c) Bjørn Bouet Smith, 2012
 *
 * This source code is subject to terms and conditions of 
 * Microsoft Public License (Ms-PL).
 * 
 * A copy of the license can be found in the license.txt
 * file at the root of this distribution. If you can not 
 * locate the License, please send an email to bjornsmith@gmail.com
 * 
 * By using this source code in any fashion, you are 
 * agreeing to be bound by the terms of the Microsoft 
 * Public License.
 *
 * You must not remove this notice, or any other, from this
 * software.
 *
 * ************************************************************/
#endregion

namespace Smith.BuildExtensions.Logging
{
    /// <summary>
    /// Class that is being used to contain log messages.
    /// </summary>
    public class Message
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="Message"/> class.
        /// </summary>
        /// <param name="level">The level.</param>
        /// <param name="formatString">The format string.</param>
        /// <param name="formatParams">The format params.</param>
        public Message(MessageLevel level, string formatString, params object[] formatParams)
        {
            Level = level;
            MessageString = string.Format(formatString, formatParams);
        }

        public string MessageString
        {
            get;
            set;
        }

        public MessageLevel Level
        {
            get;
            set;
        }
    }
}
